package com.quan.common.base.bean;

/**
 * 发送的消息
 * @author yhaoquan
 *
 */
public class WebSocketMessage {
	
	/**
	 * 消息类型：broadcast、chat
	 */
	private String type ;
	
	/**
	 * 消息显示方式：Notification, MessageBox, Message
	 */
	private String mode ;
	
	/**
	 * 消息发送者
	 */
	private String from ;
	
	/**
	 * 消息接收者
	 */
	private String to ;
	
	/**
	 * 消息标题
	 */
	private String title ;
	
	/**
	 * 消息内容
	 */
	private String message ;
	
	
	public WebSocketMessage() {
	}

	public WebSocketMessage(String type, String mode, String title, String message) {
		super();
		this.type = type;
		this.mode = mode;
		this.title = title;
		this.message = message;
	}

	public WebSocketMessage(String from, String to, String message) {
		super();
		this.from = from;
		this.to = to;
		this.message = message;
	}

	public WebSocketMessage(String type, String mode, String from, String to, String title, String message) {
		super();
		this.type = type;
		this.mode = mode;
		this.from = from;
		this.to = to;
		this.title = title;
		this.message = message;
	}

	public String getType() {
		return type;
	}

	public void setType(String type) {
		this.type = type;
	}

	public String getMode() {
		return mode;
	}

	public void setMode(String mode) {
		this.mode = mode;
	}

	public String getFrom() {
		return from;
	}

	public void setFrom(String from) {
		this.from = from;
	}

	public String getTo() {
		return to;
	}

	public void setTo(String to) {
		this.to = to;
	}

	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public String getMessage() {
		return message;
	}

	public void setMessage(String message) {
		this.message = message;
	}

	@Override
	public String toString() {
		return "WebSocketMessage [type=" + type + ", mode=" + mode + ", from=" + from + ", to=" + to + ", title=" + title + ", message=" + message + "]";
	}
	
}
